import 'package:banyou_app/app/config/colors.dart';
import 'package:banyou_app/app/widget/app_bar_widget.dart';
import 'package:flutter/material.dart';
import 'package:flutter_easyloading/flutter_easyloading.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';

import 'package:get/get.dart';

import '../controllers/jubao_controller.dart';

class JubaoView extends GetView<JubaoController> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
        appBar: AppBarWidget(titleStr: '举报'),
        body: ListView.separated(
            itemBuilder: (c, i) {
              return InkWell(
                onTap: () {
                  EasyLoading.show();
                  Future.delayed(Duration(seconds: 2), () {
                    EasyLoading.dismiss();
                    EasyLoading.showToast('举报成功');
                  });
                },
                child: Column(
                  children: [
                    ListTile(
                        trailing: Icon(
                          Icons.arrow_forward_ios,
                          size: 16,
                        ),
                        title: Text(controller.dataList[i],
                            style: TextStyle(
                                color: ColorConfig.text_label,
                                fontSize: 16.sp))),
                    Container(
                      width: 1.sw,
                      height: 1,
                      color: Color(0xFFEDEDED),
                    )
                  ],
                ),
              );
            },
            separatorBuilder: (c, i) {
              return Container();
            },
            itemCount: controller.dataList.length));
  }
}
